﻿@model WeatherType
@using WeatherForecast.Models
@{
    List<SelectListItem> list = new List<SelectListItem>();
    foreach (var value in Enum.GetValues(typeof(WeatherType)))
    {
        list.Add(new SelectListItem()
        {

            Text = value.ToString(),
            Value = ((int)value).ToString()
        });
    }
}

@(
    Html.Kendo().DropDownListFor(m=> m)
        .DataTextField("Text")
        .DataValueField("Value")
        .BindTo(list)
)

